package models

import "strings"

const (
	SaFileRecordSa       = "sa"
	SaFileRecordBa       = "ba"
	SaFileRecordHotPatch = "hotPatch"
)

func (sa *SaFileRecord) GenSaType() string {
	if strings.Contains(sa.FileName, "HotPatchSA") {
		return SaFileRecordHotPatch
	}

	if strings.Contains(sa.FileName, "BA") {
		return SaFileRecordBa
	}

	return SaFileRecordSa
}
